package com.web.main.entity.param;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.io.Serializable;

/**
 * @create 2020-11-24 19:20
 */
@NoArgsConstructor
@AllArgsConstructor
@Data
@ApiModel(value = "供应商模糊查询对象")
public class SupplierQuery implements Serializable {

    private static final long serialVersionUID = -8728748573064807162L;

    @ApiModelProperty(value = "当前页", required = true, example = "1")
    @NotNull(message = "当前页不能为空")
    private Integer page;

    @ApiModelProperty(value = "当前页记录条数", required = true, example = "4")
    @NotNull(message = "当前页记录条数不能为空")
    private Integer limit;

    @ApiModelProperty(value = "供应商名字")
    @Size(max = 10, message = "名字最大长度为{max}")
    private String name;

    @ApiModelProperty(value = "站点所在片区", example = "金牛区")
    @Size(max = 10, message = "片区地址最大字符长度为{max}")
    private String address;

}
